{{admin_start_fullscreen}}
<div class="AdminStart">
	<div class="AdminStartBlocks">
		{{foreach admin_start_block in admin_start_blocks}}
		<div class="AdminStartBlock {{if admin_start_block.big}} AdminStartBlockBig{{/if}}" data-id="{{admin_start_block.id}}">
			<div class="close" onclick="admin_start_blocks_remove({{admin_start_block.id}});"></div>
			{{admin_start_block.html}}
		</div>
		{{/foreach}}
		<div class="AdminStartBlock AdminStartPlusBlock" onclick="admin_start_blocks_add_popup()"></div>
		<div class="cl"></div>
	</div>
</div>
<script>
function admin_start_blocks_remove(id)
{
	ajaj_post("/admin-AdminStart/",{
		ajaj:1,
		mode:"remove",
		id:id
	});
	$(".AdminStartBlock[data-id='"+id+"']").animate({opacity:0},undefined,undefined,function() { $(this).remove();})
}

function admin_start_blocks_add_popup()
{
	var div=$("<div title='Add widget'><iframe src='/admin_popup-AdminStart/?mode=add' border='0' frameborder='0' width='100%' height='100%'></iframe></div>").appendTo($("body")).dialog({
		height:400,
		width:600,
		modal:true,
		resizable: false,
		close: function() {
			div.remove();
		}
	});
}
</script>
<!-- site.language = {{site.language}} -->
